package com.mutouren.modules.org.service;

import java.util.List;

import org.springframework.beans.factory.InitializingBean;

import com.mutouren.common.entity.PageInfo;
import com.mutouren.common.orm.spring.BaseService;
import com.mutouren.modules.org.model.Function;
import com.mutouren.modules.org.model.Role;

public interface RoleService extends BaseService<Role>, InitializingBean {
	
	List<Role> selectByAppId(int appId);
	
	int addToOrg(int orgId, int roleId);
	void removeFromOrg(int orgId, int roleId);
	
	void setFunctions(int roleId, List<Integer> listFuncId);
	List<Function> getFunctions(int roleId);
	
	void addFunction(int orgId, int funcId);
	void deleteFunction(int orgId, int funcId);
	
	List<Role> selectByOrgId(int orgId, boolean isInherit, PageInfo pageInfo);
}
